package toOffer;

import java.util.LinkedList;

/**
 * <h3>leetcode</h3>
 *
 * @author BigFaceCat
 * @date 2024/1/31 20:46
 * @description <p>图书整理 II</p>
 */

/**
 * 用linkedList模拟栈就好
 * linkedlist比stack要好
 */
public class LCR125NO {

    private static LinkedList<Integer> stack = new LinkedList<>();

    public LCR125NO() {

    }

    public void appendTail(int value) {
        stack.push(value);
    }

    public int deleteHead() {
        return stack.pop();
    }
}

/**
 * Your CQueue object will be instantiated and called as such:
 * CQueue obj = new CQueue();
 * obj.appendTail(value);
 * int param_2 = obj.deleteHead();
 */
